Skip to content

Conversation

@errmayank
Copy link
Contributor

Closes #35817

Release Notes:

  • Fixed cursor disappearing on panel open

Here's a before/after:

screen-recording-cursor-disappear.mov

@cla-bot cla-bot bot added the cla-signed The user has signed the Contributor License Agreement label Nov 8, 2025
Copy link
Member

@MrSubidubi MrSubidubi left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for this!

Unfortunately, I do not think this is the proper fix - this will not hide the cursor in cases where it should actually be hidden.

The issue then is, though, that this will require a LOT more changes to get properly right. As of now, this guard has to be manually added for each and every editor and be updated accordingly, set with the correct enum variant. Additionally, we also had to add a special hitbox behavior for this specific change (I can search for that PR later). Yet, as seen here, this is really prone to errors and should be resolved differently IMO.

I think we should instead push the handling of this setting up to the workspace. Then, we can differentiate between movement and typing more easily. However, this will require a larger refactor some more changes to the backend on Linux I think, I'll check with some of the folks internally on this.

Hence, I do not think this is the proper fix for the issue at hand. Would you be up for the bigger scope? Happy to get that working together with you, but as said, that might be a larger chunk of work.

@errmayank
Copy link
Contributor Author

@MrSubidubi Makes sense, happy to take this on!

So from what I understand, we need to get rid of all the hide_mouse_cursor() calls in editor and handle it at workspace level, maybe via an action?

Additionally, we also had to add a special hitbox behavior for this specific change (I can search for that PR later)

Let me know what PR this was, appreciate it.

Maybe we can later pair to make sure we're on the same page.

@MrSubidubi
Copy link
Member

So from what I understand, we need to get rid of all the hide_mouse_cursor() calls in editor and handle it at workspace level, maybe via an action?

Yes, but definitely not via an action. I think we could have a listener at the workspace level via

pub fn intercept_keystrokes(
which hides for the on_input part of the hiding, whereas for the movement/action part, I lack a good idea right now (perhaps you find one).

Then, whenever we detect a key dispatch, we hide the cursor.

I already pinged people internally about this, so please note that we might actually need some new APIs for this to be properly fixed. But given that you are on MacOS, should actually be fine for you right now (you can dig through the PR that follows for some context, happy to explain that some other time).

PR in question was #32795 and related ones.

So, feel free to start on this. However, please do also note that, as noted, this might require some adjacent changes, so could take some more time before I can merge this. Thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

cla-signed The user has signed the Contributor License Agreement

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Cursor Disappears When Opening Collab Panel via Status Bar Icon Button

2 participants